﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

using Data.DataAccess.Database;

namespace Test.DataAccessTest
{
    class Program
    {
        static void Main(string[] args)
        {
            DbUserAccess oTfsUserAccess = new DbUserAccess(@"Data Source=.\SQL2008; Initial Catalog=TfsPendingCheckin; Integrated Security=True;");

            TFS_USER oUser = new TFS_USER();
            oUser.USER_LOGIN = "user";
            oUser.USER_EMAIL = "user@mail.com";

            oTfsUserAccess.AddUser(oUser);
            Console.WriteLine("User added.");
            Console.WriteLine("Press any key to continue...");
            Console.ReadKey();

            oUser = oTfsUserAccess.GetUser("user");
            Console.WriteLine(oUser.USER_ID + " " + oUser.USER_LOGIN + " " + oUser.USER_EMAIL);
            Console.WriteLine("Press any key to finish...");
            Console.ReadKey();
        }
    }
}
